fix(tui): retry acts on the displayed generation, not the session file#49
Merged
Merged
Conversation
The TUI retry action discarded the dashboard's active generation_id and re-derived it from specflow_session.json at the SpecFlow checkout root (resolve_repo_root), where no session file exists when the run belongs to another project or was opened from the Sessions list. cmd_retry_generation also hardcoded resolve_generation_id(None, ...), ignoring any explicit id. Result: retry printed "No previous generation found" and no-oped, leaving the session FAILED. Thread the on-screen generation_id through do_retry into cmd_retry_generation (session file remains the fallback), matching the download-outputs pattern, and add --generation-id to the retry-generation subparser.
Contributor
|
@mkonopelski-gd Please check tests as they did not pass |
akozak-gd
approved these changes
Jul 14, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
TUI retry silently no-ops and drops to the terminal instead of resuming a failed generation.
Root cause: the retry action threw away the dashboard's active
generation_idand re-derived it fromspecflow_session.jsonatself.app.root. That root is the SpecFlow checkout (resolve_repo_root), not the project the run belongs to — so when the session was opened from the Sessions list (or the run lives in another project directory), no session file is found there.cmd_retry_generationcompounded it by hardcodingresolve_generation_id(None, ...), ignoring any explicit id. Retry printed "No previous generation found" and returned without calling the backend, leaving the sessionFAILED.Fix
generation_idthroughdo_retry→cmd_retry_generation; the session file stays as the fallback (mirrors thedownload-outputspattern).--generation-idto theretry-generationsubparser soargs.generation_idalways exists.Tests
make unit-testsmake integration-testsmake skip-mode-e2e-tests